module.exports = {
  nav_name: '广告管理', //生成导航菜单
  module_name: 'advertisement_manager',  //生成路径，与模块名相同
  api: `{
    page: commonPath + "/admin/user/advertis/page", // 分页
    changeState: commonPath + '/admin/user/advertis/editState', //状态
  }`,
  table: {
    isGenerate: "false",
    nav_name: "广告审核列表",
    tipsText: "广告管理 >> 广告审核列表",
    //获取列表页面
    tableData: [
      { title: '序号', name: 'index', type: "normal" },
      {
        title: '广告图片',
        name: 'advImg',
        type: "img",
        heightVal: "60",
        widthVal: "100",
      },
      {
        title: '标签',
        name: 'labelValue',
        type: "normal",
      },
      {
        title: '状态',
        name: 'autoState',
        type: "opts",
        showName: "stateShow",
        showObj: `{
          "0": "待审核",
          "1": "通过",
          "2": "未通过",
          "": "全部",
        }`
      },
    ],
    tableOpt: [
      // {
      //   type: "view",
      //   text: "查看",
      //   request: false,
      //   jump: "/member_manager/see_detail_member查看"
      // },
      {
        type: "changeState",
        text: "通过",
        request: true,
        url: "API.advertisement_manager.changeState",
        requestType: 'post',
        params: `{ id, state: 1 }`,
        methodNameTag: 'Pass', //方法衔接拓展名 用于标志不同方法
        isSplitSearchString: 'true', //拼接查询字符串
        showCondition: "scope.row.autoState == '0'",
      },
      {
        type: "changeState",
        text: "拒绝",
        request: true,
        url: "API.advertisement_manager.changeState",
        requestType: 'post',
        params: `{ id, state: 2 }`,
        methodNameTag: 'Reject', //方法衔接拓展名 用于标志不同方法
        isSplitSearchString: 'true', //拼接查询字符串
        showCondition: "scope.row.autoState == '0'",
      },
    ],
    search: {
      contentArr: {
        select1: {
          labelName: '审核状态',
          inputName: 'autoState',  //输入绑定的变量
          selectOptsName: "autoStateOpts",
          selectOptsArr: `[
            { value: "0", label: "待审核" },
            { value: "1", label: "通过" },
            { value: "2", label: "未通过" },
          ],
          `, //选项数组
        },
      },
      searchBtn: {
        text: "查询", //链接与table请求接口相同，不做另外配置
      },
      // addBtn: {
      //   //搜索栏具有添加功能按钮时，设置此字段
      //   type: "add",
      //   text: "添加",
      //   request: false,
      //   jump: "/member_manager_add_page"
      // }
    },
  },

  // //详情页面
  // detail_page: {
    
  // }
}
